from modeltranslation.translator import translator, TranslationOptions
from models import *
from snippets.models import Snippet

class GoodTranslationModels(TranslationOptions):
    fields = ('title',)

class NewsTranslationModels(TranslationOptions):
    fields = ('title','anounce','text')

class SnippetTranslationModels(TranslationOptions):
    fields =('content',)

translator.register(Good, GoodTranslationModels)
translator.register(MenGoodClass, GoodTranslationModels)
translator.register(WomenGoodClass, GoodTranslationModels)
translator.register(DecorGoodClass, GoodTranslationModels)
translator.register(Collection, GoodTranslationModels)
translator.register(New, NewsTranslationModels)
translator.register(Snippet, SnippetTranslationModels)

from django.contrib.flatpages.models import *
class FlatPageTranslationOptions(TranslationOptions):
    """
    Translation of `FlatPage`.
    """
    fields = (
        'title',
        'content', )
translator.register(FlatPage, FlatPageTranslationOptions)